<div id="signupModal" class="modal fade user-signup-modal" tabindex="-1" role="dialog" aria-labelledby="signupModalLabel" aria-hidden="true" (click)="changeModal('hide')">
    <div class="modal-dialog">
        <div class="modal-content" (click)="$event.stopPropagation()">
            <div class="modal-body">
                <img *ngIf="userService.isToken" src="/static/images/close_icon.png" alt="close" class="btn-close" (click)="changeModal('hide')">
                <div class="signup">
                    注册
                </div>
                <form role="form" name="signupForm" class="form-signup" novalidate>
                    <div class="form-group input-form">
                        <img src="/static/images/user_id.png" alt="user-id" class="user-id-img">
                        <input id="signup-username" name="mobile" type="tel" required [(ngModel)]="signUser.mobile" placeholder="请输入手机号">
                    </div>
                    <div class="form-group input-form otp-form">
                        <img src="/static/images/user_sms.png" alt="user-sms" class="user-sms-img">
                        <input class="form-control otp" id="signup-smsCode" name="smsCode" type="text" [(ngModel)]="signUser.smsCode" placeholder="请输入验证码" ng-minlength="6" ng-maxlength="6" required>
                        <span class="getSms" (click)="sendSmsCode(); $event.preventDefault();" *ngIf="waitTime<=0">获取验证码</span>
                        <span class="disabled" *ngIf="waitTime>0">重新发送({{waitTime}})</span>
                    </div>
                    <div class="form-group forget-form">
                        <div class="agreement">
                            注册即代表同意
                            <span (click)="clickAgreement()">《用户协议》</span>
                        </div>
                    </div>
                    <div class="form-group signup-form">
                        <div class="button-style" [class.disabled]="!(this.signUser.mobile && this.signUser.smsCode && this.signUser.smsToken)">
                            <button class="btn btn-primary" type="submit" (click)="signup()">注册</button>
                        </div>
                        <div class="signup-err"><span *ngIf="errText">{{errText}}</span></div>
                    </div>
                    <div class="goLogin">
                        已有帐号？去
                        <span (click)="changeModal('login')">登录</span>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
<user-agreement *ngIf="status === 'clicked'" (setModal)="closeAgreement($event)"></user-agreement>